package Demo;

import java.util.concurrent.locks.Lock;
import java.util.concurrent.locks.ReentrantLock;

public class Demo22 {
    public static void main(String[] args) {
        ReentrantLock reentrantLock = new ReentrantLock(true);
        try {
            reentrantLock.lock();
        } finally {
            reentrantLock.unlock();
        }

        // reentrantLock.tryLock();
    }
}
